package cn.itcast.consumer.client;

import cn.itcast.consumer.pojo.User;
import org.springframework.stereotype.Component;

/**
 * 就是UserClient接口的fallback类
 * @author 虎哥
 */
@Component
public class UserClientImpl implements UserClient{
    @Override
    public User queryUserById(Long userId) {
        User user = new User();
        user.setId(userId);
        user.setName("用户查询出现异常！");
        return user;
    }
}
